﻿using Adaptive.Agrona.Concurrent;

using Unity.Connections;

namespace Unity.Commons.Client.Buffer
{
    public interface IUnityBuffer
    {
        int Claim(int length);
        void Commit(int index);
        void Abort(int index);
        IAtomicBuffer GetBuffer();
        IUnityProducer GetProducer();
        ClientMode GetMode();
        
        long GetBufferCapacity();
        long GetBufferSize();
        long GetPublished();
        long GetDropped();

        void Start();
        void Close(long timeout);
        void Close();

    }
}
